The present invention relates to sharing memory among computer processes.
A virtual memory system automatically moves a program's data back and forth between slower, lower-cost secondary memory and faster, higher-cost, primary memory, so that the program's more-referenced data tend to reside in the faster memory, and less-referenced data tend to reside in the slower memory. A program's data are divided into fixed-size blocks, called "pages." More-referenced pages are kept in primary storage. As references to the page become less frequent, the less-referenced page is moved to secondary storage. In a computer with a virtual memory system, programs reference data by virtual address. Address translation hardware translates program-visible virtual addresses to physical addresses (a physical address is the address in primary memory at which the data actually reside).
The translation from virtual addresses to physical addresses is called the "mapping," and is described by a "page table," a table that associates pages of virtual addresses to pages of physical addresses. The page table is itself divided into pages. The pages of the page table are typically arranged as a tree, with a base pointer forming the root at the top of the tree, higher-level nodes in the tree indicating the mapping at coarser level, and lower-level nodes in the tree indicating the mapping at finer levels. The memory pages actually read, written, and executed by programs form the leaf nodes at the bottom of this tree.
Virtual memory systems and multi-level address translation are described in "Structured Computer Organization," second edition, by Andrew S. Tanenbaum, Prentice-Hall, 1984, "VAX/VMS Internals and Data Structures," by Lawrence J. Kenah and Simon F. Bate, Digital Press, 1984, "OpenVMS AXP Internals and Data Structures, Version 1.5" by R. Goldenberg ad S. Saravanan, Digital Press, 1994, "Extending OpenVMS for 64-bit Addressable Virtual Memory," Digital Technical Journal vol. 8 no. 2 (1996), and "Alpha AXP Architecture Reference Manual," second edition, by Richard L. Sites and Richard T. Witek, Digital Press, 1995, each incorporated herein by reference.
It is known to provide shared memory among multiple processes executing on a computer. In a typical implementation, two processes agree on the physical page number in which the shared data are stored, and the page tables of the two processes are each set to point to that agreed physical page.